package com.hz.friends.db;

import java.io.Serializable;
import java.util.Date;

import com.avos.avoscloud.AVUser;

public class DBContactUser implements Serializable {
	private String userid; // 用户id
	private String heardurl; // 用户头像url
	private String nickname; // 用户昵称
	private String lastContent; // 用户聊天最后
	private Date time; // 最后更新时间

	public DBContactUser(){
		
	}
	public DBContactUser(AVUser avuser){
		userid = avuser.getObjectId();
		heardurl = avuser.getString("headViewURL");
		nickname = avuser.getString("nickname");
	}
//	public DBContactUser(AVUser avuser,String lastContent){
//		userid = avuser.getObjectId();
//		heardurl = avuser.getString("headViewURL");
//		nickname = avuser.getString("nickname");
//		this.lastContent = lastContent;
//	}
	
	
	public DBContactUser(AVUser avuser,String lastContent,Date time){
		userid = avuser.getObjectId();
		heardurl = avuser.getString("headViewURL");
		nickname = avuser.getString("nickname");
		this.lastContent = lastContent;
		this.time = time;
	}
 
	public String getUserid() {
		return userid;
	}

	public void setUserid(String userid) {
		this.userid = userid;
	}

	public String getHeardurl() {
		return heardurl;
	}

	public void setHeardurl(String heardurl) {
		this.heardurl = heardurl;
	}

	public String getNickname() {
		return nickname;
	}

	public void setNickname(String nickname) {
		this.nickname = nickname;
	}

	public String getLastContent() {
		return lastContent;
	}

	public void setLastContent(String lastContent) {
		this.lastContent = lastContent;
	}

	public Date getTime() {
		return time;
	}

	public void setTime(Date time) {
		this.time = time;
	}

}
